<template>
  <!-- 新增弹窗 -->
  <Modal v-model="modal1" title="创建用户" @on-ok="asyncOK" :loading="loading">
    <Form :model="addForm" :label-width="100">
      <FormItem label="企业名称" prop="shortName">
        <Input v-model="addForm.shortName" placeholder="请输入" />
      </FormItem>
      <FormItem label="所属公司" prop="company">
        <Input v-model="addForm.company" placeholder="请输入" />
      </FormItem>
      <FormItem label="省份" prop="province">
        <Input v-model="addForm.province" placeholder="请输入" />
      </FormItem>
      <FormItem label="城市" prop="city">
        <Input v-model="addForm.city" placeholder="请输入" />
      </FormItem>
      <FormItem label="标签" prop="tags">
        <Input v-model="addForm.tags" placeholder="请输入" />
      </FormItem>
      <FormItem label="备注" prop="remarks">
        <Input v-model="addForm.remarks" placeholder="请输入" />
      </FormItem>
    </Form>
  </Modal>
</template>

<script>
export default {
  props: {
    // 弹窗显示
    modal1: {
      type: Boolean,
      default: false
    }
  },
  data () {
    return {
      loading: true,
      // 新增用户表单
      addForm: {
        shortName: '', // 企业简称
        company: '', // 所属公司
        province: '', // 省份
        city: '', // 城市
        tags: '', // 标签
        remarks: '' // 备注
      },
      // 新增用户表单验证
      addRuleValidate: {
        shortName: [],
        company: [],
        province: [],
        city: [],
        tags: [],
        remarks: []
      }
    }
  },
  methods: {
    asyncOK () {
      console.log('关闭')
      this.$emit('close')
    }
  }
}
</script>

<style>
</style>
